/*
 * Game.h
 *
 *  Created on: 15/07/2008
 *      Author: Samuk
 */

#ifndef CAPP_H_
#define CAPP_H_

#define MAPA "padrao"

#include <string>
#include <SDL.h>
#include <SDL_image.h>
#include <map>

#include "framework/utils/UtilSDL.h"
#include "framework/CSurface.h"
#include "framework/CEvent.h"

#include "stickbombers/comum/SBMap.h"
#include "stickbombers/components/components.inc.h"

class StickBombers: public CEvent {

public:
	SDL_Surface* SurfDisplay;
	CMap* MapAtivo;
	Player* EntPlayer;
	bool Rodando;

	static StickBombers* Instance();
	static void Release();
	static void Destroy();

	void ConfiguraMapa(char* Mapa);
	void ConfiguraPlayer();

	bool OnInitialize();
	void OnEvent(SDL_Event* event);
	void OnLoop();
	void ExecutaLimpeza();
	void OnRender();
	void OnCleanup();
	void RemoveEntidades();
	void RemoveSurfaces();
	void OnExit();

private:
	virtual ~StickBombers();
	static StickBombers* _instance;
	static int _refCount;

protected:
	StickBombers();
};

#endif /* CAPP_H_ */
